<!-- <div class="row">
  <h1 translate lib="web">workflows</h1>
  <p class="col-md-5 lead"></p>
</div> -->
<div class="row">
  <div class="col-sm">
    Start an instance of one of these workflow
  </div>
  <div class="col-sm"></div>
  <div class="col-sm text-right">
    <em class="fas fa-cog fa-spin" ng-show="ctrl.loading==true"></em>
  </div>
</div>
<div ng-show="ctrl.errormessage != ''"" class=" alert alert-danger" role="alert">{{ctrl.errormessage}}</div>
<div class="row">
  <table id="table1" class="table table-striped" when-scrolled="ctrl.more()" style="width: 100%;">
    <thead class="thead-dark">
      <tr>
        <th ng-click="ctrl.ToggleOrder('name')"><strong translate lib="web">name</strong></th>
        <th class="w-200" ng-click="ctrl.ToggleOrder('_createdby')"><strong translate lib="web">createdby</strong></th>
        <th class="w-150"></th>
      </tr>
    </thead>
    <tbody>
      <tr ng-repeat="model in ctrl.models">
        <td><a style="color: inherit; text-decoration: inherit;" ng-href="#/Form/{{model._id}}">{{model.name}}</a></td>
        <td>{{model._createdby}}</td>
        <td>
          <a ng-href="#/Form/{{model._id}}" class="btn"><em class="fas fa-play-circle"></em></a>
          <a href ng-click="ctrl.DeleteOne(model)" class="btn"><em class="fas fa-trash"></em></a>
        </td>
      </tr>
    </tbody>
  </table>